What's Model
From Documentation
This documentation is for an older version of ZK. For the latest one, please click here.
To assign data to a component (e.g. grid
or listbox
), you have to prepare the data in certain data model. For example, listbox
and grid
accept interfaces ListModel
and GroupsModel
, while tree
only accepts TreeModel
. See the setModel
method of each component for the kind of model it accepts. Using the wrong type of data model will throw a cast error and is a common beginner mistake.
ZK has implemented following Models:
- SimpleCategoryModel
- SimpleGroupsModel
- SimpleListModel
- SimplePieModel
- SimpleTreeModel
- SimpleXYModel
- SimpleXYZModel
- SimpleHiLoModel